'''
功能需求：
作业一：编写登录借口
    a.输入用户名密码
    b.认证成功后显示欢迎信息
    c.输错三次后锁定
'''
name = input("please input your name:")
passwd = input("please input your passwd:")
realName = "root"
realPwd = "root"
flag = 1
flag = int(flag)
while flag < 4:
    if (name == realName) & (realPwd == passwd):
        print("welcome!")
        break
    else:
        name = input("please input your name:")
        passwd = input("please input your passwd:")
        flag = flag + 1
    if flag ==4:
        print("your account is lock!")